<template>
  <div class="about">
<<<<<<< HEAD
    <h1>This is an about page</h1>
  </div>
</template>
=======
    <h1 @click="jumpPage">This is an about page</h1>
    <button @click="jump2">传参数</button>
    <button @click="jump3">传参数3</button>
  </div>
</template>
<script>
export default {
  name:'about',
  methods: {
    jumpPage(){
      this.$router.go(-1)
    },
    jump2(){
      this.$router.push({
        name:'news',
        params:{
          id:12//传参  但是缺点是刷新时 参数会丢失
        }
      })
    },
    jump3(){
      this.$router.push({
        name:'news',
        query:{
          id:13//传参 这种方式刷新时不会丢失但是没有隐私性
        }
      })
    }
  },
}
</script>
>>>>>>> 6bf8714517698cba3c843e451acfb7d17c339c11
